/**
 * Created by evenvi on 17-12-26.
 */

var url = 'http://www.cnblogs.com/qiyeboy/';
var page = require('webpage').create();
page.onConsoleMessage = function (msg) {
    console.log('Page title is ' + msg);
};
page.open(url, function (status) {
    var title = page.evaluate(function () {
        return document.title
    });
    console.log('Page title is ' + title);
    phantom.exit();
});
